<%--
  Created by IntelliJ IDEA.
  User: dell
  Date: 2018/5/27
  Time: 19:37
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <title>用户编辑</title>

    <script type="text/javascript">
        function validateForm() {
            var x = document.forms["form"]["username"].value;
            var y = document.forms["form"]["password"].value;
            if (x == null || x == "") {
                alert("用户名不能为空。");
                return false;
            }
            if (y == null || y == "") {
                alert("密码不能为空.");
                return false;
            }
        }
    </script>
</head>
<body>
<form method="post" action="userUpdate.jsp" name="form" onsubmit="return validateForm()">

    <input type="text" hidden="hidden" name="id" id="id"
           value="<%=request.getParameter("id")%>"><br/>
    用户名：<input type="text" name="username" id="username"
               value="<%=request.getParameter("username")%>"><br/>
    密码：<input type="text" name="password" id="password"
              value="<%=request.getParameter("password")%>"><br/>
    <button type="submit">确认编辑信息</button>
</form>
</body>
</html>
